#!/usr/bin/env python
# -*- coding: utf-8 -*-
# Created by Kumikoda on 2017/6/17

import sys
reload(sys)
sys.setdefaultencoding('utf-8')

# mysql info
db_info = {
    'host' : '47.52.93.128',
    'port' : 3306,
    'user' : 'aops',
    'passwd' : 'qqq772',
    'db' : 'aops',
    'charset' : 'utf8',
}

# redis info
redis_info = {
    'host' : '127.0.0.1',
    'port' : 6379,
    'db': 0,
    'password' : 'p@ssw0rd',
    'encoding' : 'utf-8'
}

# juhe api key [url key]
juhe_api_key = {
    '12306' :
        ['http://apis.juhe.cn/train/s','0d664538f522bcb744fc0457d0992489'],
    'webscan' :
        ['http://apis.juhe.cn/webscan','7b35757bdd5da1e5f2bace6a3b1bba2c'],
    'postcode' :
        ['http://v.juhe.cn/postcode/query','cf0f6e5be4c99d7b0cc83a2452b89a42'],
    'ip' :
        ['http://apis.juhe.cn/ip/ip2addr','1999ea765ad08cb95b6cc0129544b90a'],
    'question' :
        ['http://op.juhe.cn/robot/index','978f281744b2cda30642dbbaf3eb8349'],
    'small' :
        ['http://japi.juhe.cn/joke/content/list.from','7947f711377da1612b1a587f0321a5fb'],
    'idcard' :
        ['http://apis.juhe.cn/idcard/index','7fa264c47af134c52f5099924681b99d'],
    'phone' :
        ['http://apis.juhe.cn/mobile/get','553309f6404564bb832992b08c4a7851']
}

#smsbao api info
smsbao_api_key = {
    'url' : 'http://api.smsbao.com/sms',
    'user' : 'kumikoda',
    'passwd' : '1b2853a309fb00d6934ff7bcfce8d281'
}

#uploads local path
upath = './uploads'

#uploads remote path 目录后加/
rupath = '/tmp/'

#downloads path
downpath = './downloads'

'''
0 正确
1-100 用户类错误
    1-50 登陆
    50-100 注册
'''

'''
0 正确

'''

_code = {
	0 : '成功' ,
	1 : '用户不存在' ,
	2 : '用户未激活' ,
	3 : '密码输入错误' ,
    51 : '请填写相应信息',
    52 : '用户手机号不正确',
    53 : '密码不一致' ,
    54 : '注册失败' ,
    55 : '手机号已存在，请更换手机号',
    56 : '查询所有用户时出错' ,
    57 : '用户激活失败',
    58 : '用户导入数据成功',
    59 : '主机已经存在',
    60 : '修改机器成功',
    61 : '业务类型月计费统计成功',
    62 : '服务器统计成功'
}